from fastapi import APIRouter, Depends

router = APIRouter()

class FixedContentQueryChecker:
    def __init__(self,fixed_content: str):
        self.fixed_content = fixed_content

    def __call__(self, q: str = ""):
        if q:
            return self.fixed_content in q
        return False

checker = FixedContentQueryChecker("hello")

@router.get("/query_checker")
async def query_checker(fixed_content_included: bool = Depends(checker)):
    if fixed_content_included:
        return {"message": "Query contains hello"}
    return {"message": "Query does not contain hello"}